package com.yangwei.examination.teacher.mappers;

import com.yangwei.examination.teacher.pojo.BankQuestion;
import com.yangwei.examination.teacher.pojo.PaperQuestion;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.Mappings;
import org.mapstruct.factory.Mappers;

@Mapper(componentModel = "spring")
public interface PaperQuestionDtoMapper {

    PaperQuestionDtoMapper INSTANCE = Mappers.getMapper(PaperQuestionDtoMapper.class);

    @Mappings({
            @Mapping(target = "id",  ignore = true),
            @Mapping(target = "selected", ignore = true),
    })
    PaperQuestion toPaperQuestionDto(BankQuestion bankQuestion);

}
